In real-time sampled-signal processing such as digital filtering, each output sample depends typically on a number of input samples and, in the case of recursive processing such as infinite impulse response (IIR) filtering, additionally on past output samples. In most applications there will be a correspondence in time between input samples and output samples. For example, an event in the input signal that is preserved by the process would be considered to be contemporaneous with the corresponding event in the output signal. In many cases it is desirable that the process has access to input samples both in the past and in the future. However, since a causal system cannot in reality access future samples, the process has to wait until the last required input sample has arrived before it can produce its output. This waiting period is known as the latency or pipeline delay of the process.
The latency of a process is therefore defined as the number of sample periods of delay that elapses between an event at the input to the process and the corresponding event at the output. In general, this delay need not be an integer; for example, the delay of a filter whose output is the average of input signals across a sample-period delay will be 0.5 sample periods. Latency is related to but not in general identical to group delay; however, for a symmetric or linear-phase filter such as the example just given, latency and group delay are identical. In the description that follows, latency is usually expressed as a whole number and may also be thought of as the number of “future” samples that would have to be made available to the filter in order for there to be no delay between input and output events.
This invention relates to processes or filters which are linear (at least instantaneously). By linear is meant that a linear transformation applied to the original input of the process or filter will result in a new output which is related by the same linear transformation to the original output. So, for example, processes involving rank ordering, quantisation or envelope detection are not linear processes.
Let us illustrate the property of latency in the case of a linear sampled-signal filter.
Consider a sampled input signal f(t) where t takes integer values. Suppose we wish to perform a filtering operation on this signal where the output depends on surrounding input and output samples:g(t)=G(f(t−n),f(t−n−1), . . . ,f(t+m),g(t−k),g(t−k+1), . . . ,g(t−1)where m, n and k are positive integers. In the case of a symmetric finite impulse response (FIR) filter, m=n and k=0 and there is a direct, unambiguous correspondence between g(t) and f(t). In the more general case, we assume that an input event at a sample labelled t would be manifest at the output at the sample labelled t.
The output of this filter at any moment thus depends on m+n+1 input samples, which are considered to extend from n sample periods in the “past” to m sample periods in the “future”, and on k “past” output samples.
This filtering operation may be represented diagrammatically as shown in FIG. 1. In this example, n=4, m=3 and k=5.
Because the output of the filter at time t depends on input samples considered to be up to m sample periods later than time t, the output cannot actually be calculated until time t+m, as represented in FIG. 2, where the samples are aligned with a time axis. We say in this case that the filter has a latency, or pipeline delay, of m=3 sample periods.
When designing a filter, there are two conflicting requirements regarding latency. In many applications, it is desirable to have access to a large number of “future” input samples. For example, if the object is to smooth or low-pass filter the signal, then many input samples are required, and if constant group delay is required, the filter also needs to be symmetric, so about half the samples need to be “future” samples, giving rise to a high latency. However, in real-time processing it is also desirable to minimize the latency so that the filter responds quickly to events at the input.
It is the object of certain aspects of this invention to provide a method or apparatus for real-time signal processing with low latency that retains some or all of the performance advantages available from processes with higher latency.